import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 高生平
 * Date: 2025-09-06
 * Time: 19:11
 */
public class Test {
    public static int sum (int n) {
        if (n < 10) {
            return n;
        }
        return sum(n / 10) + n % 10;
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while (sc.hasNextInt()) {
            int num = sc.nextInt();
            System.out.println(num + "的每位之和为：" + sum(num));
        }
    }
}
